<?php

namespace app\models;

use Yii;

/**
 * This is the model class for table "crm_system_gsxx".
 *
 * @property int $id
 * @property string $name 名称
 * @property string $bz 备注
 * @property int $pid 父id
 * @property string $type 类型
 * @property array $permission 权限
 */
class CrmSystemGsxx extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 'crm_system_gsxx';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['pid'], 'integer'],
            [['permission'], 'safe'],
            [['name'], 'string', 'max' => 40],
            [['bz'], 'string', 'max' => 255],
            [['type'], 'string', 'max' => 60],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'name' => '名称',
            'bz' => '备注',
            'pid' => '父id',
            'type' => '类型',
            'permission' => '权限',
        ];
    }
}
